 window.onload = function () {
        var itemmain = document.getElementsByClassName('item-main')[1];
        var nlabe = document.getElementById('nlabe');
        var links = document.getElementsByClassName('links')[0];
        console.log(itemmain);

        nlabe.onclick = function () {
            // foott.style.height='80px';
            if (nlabe.innerHTML == '收起') {
                nlabe.innerHTML = '展开';
                links.style.height = '78px';
            } else {
                nlabe.innerHTML = '收起';
                links.style.height = '248px';
               
            }
        };

        // window.onscroll=function(){
        //         var scrollTop = document.documentElement.scrollTop || document.body.scrollTop;
        //        var head = document.getElementsByClassName('head')[0];
        //         console.log(scrollTop)
        //         if(scrollTop>300){
        //         head.style.display='block';
        //         }else if(scrollTop<300){
        //         head.style.display='none';
        //         }
        //         if(!isbool){
        //             clearInterval(oTime);
        //         }
        //         isbool=false;
        //     }


    window.onscroll=function(){
        var oScrollTop = document.documentElement.scrollTop||document.body.scrollTop;
        var goHeader = document.getElementsByClassName('goheader')[0];
        var oGoHeader = document.getElementsByClassName('goheader-1')[0];

        if(oScrollTop > 320){
            goHeader.classList.add('show');
            oGoHeader.style.display='block';
        }else if(oScrollTop < 320){
            goHeader.classList.remove('show');
            oGoHeader.style.display='none';
        }
    }




    var boxHome = document.getElementsByClassName('boxHome');
    var prev = document.getElementsByClassName('prev')[0];
    var next = document.getElementsByClassName('next')[0];
    var homemaint= document.getElementsByClassName('home-main-three')[0];
    var boxHomeBottom = document.getElementsByClassName('boxHome-bottom')[0];
    var one = document.getElementById('one');
    var two = document.getElementById('two');
    var three = document.getElementById('three');
    prev.onclick = function() {
        boxHomeBottom.style.display = "none";
        homemaint.style.display = "block";
        one.style.background = "#62D5C8";
        three.style.background = "#fff";

    }
    next.onclick = function() {
        boxHomeBottom.style.display = "block";
        homemaint.style.display = "none";
        three.style.background = "#62D5C8";
        one.style.background = "#fff";
    }


    var tan = document.getElementById('tan');
    var btn = document.getElementById('btn');
    tan.onclick = function showDiv(){
        document.getElementById('popDiv').style.display='block';
        document.getElementById('bg').style.display='block';
        }
    btn.onclick = function closeDiv(){
        document.getElementById('popDiv').style.display='none';
        document.getElementById('bg').style.display='none';
        }


}
